function getFileUrl(file){
    return getObjectURL(file);
}

function getImgInfo(file, callbackFun) {
    EXIF.getData(file, function () {
        var time = EXIF.getTag(this,"DateTimeOriginal")
        if(time === undefined){
            callbackFun(time);
        }else{
            var timeArr = time.split(" ");
            var result = timeArr[0].replace(/:/g,"-") +" "+ timeArr[1];
            callbackFun(result);
        }
    });
}

function getObjectURL(file) {
    var url = null ;
    if (window.createObjectURL!=undefined) { // basic
        url = window.createObjectURL(file) ;
    } else if (window.URL!=undefined) { // mozilla(firefox)
        url = window.URL.createObjectURL(file) ;
    } else if (window.webkitURL!=undefined) { // webkit or chrome
        url = window.webkitURL.createObjectURL(file) ;
    }
    return url ;
}